const Main = imports.ui.main;
const Params = imports.misc.params;
+const ScreenSaver = imports.misc.screenSaver;
// This manages the shell "chrome"; the UI that's visible in the
// normal mode (ie, outside the Overview), that surrounds the main
Main.overview.connect('hidden',
Lang.bind(this, this._overviewHidden));
+ this._screenSaverProxy = new ScreenSaver.ScreenSaverProxy();
+ this._screenSaverProxy.connect('ActiveChanged', Lang.bind(this, this._onScreenSaverActiveChanged));
+ this._screenSaverProxy.GetActiveRemote(Lang.bind(this,
+ function(result, err) {
+ if (!err)
+ this._onScreenSaverActiveChanged(this._screenSaverProxy, result);
+ }));
+
this._relayout();
},
this._queueUpdateRegions();
},
+ _onScreenSaverActiveChanged: function(proxy, screenSaverActive) {
+ this.actor.visible = !screenSaverActive;
+ this._queueUpdateRegions();
+ },
+
_findMonitorForRect: function(x, y, w, h) {
// First look at what monitor the center of the rectangle is at
let cx = x + w/2;